package com.sharp.authorization.dao.common.entity;

import com.sharp.kernel.config.db.key.SequenceGenId;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import java.util.Date;
import javax.persistence.*;
import lombok.Data;
import tk.mybatis.mapper.annotation.KeySql;

/**
 * Title: AcRole
 * Description: Copyright: Copyright (c) 2019 Company: BHFAE
 *
 * @author Sharp
 * @date 2022/6/16 14:20
 */

/**
 * 角色表
 */
@ApiModel(value = "com-sharp-authorization-dao-common-entity-AcRole")
@Data
@Table(name = "ac_role")
public class AcRole {
    /**
     * 角色ID
     */
    @Id
    @Column(name = "id")
    @ApiModelProperty(value = "角色ID")
    @KeySql(genId = SequenceGenId.class)
    private String id;

    /**
     * 父角色ID
     */
    @Column(name = "parent_role_id")
    @ApiModelProperty(value = "父角色ID")
    private String parentRoleId;

    /**
     * 角色名称
     */
    @Column(name = "`name`")
    @ApiModelProperty(value = "角色名称")
    private String name;

    /**
     * 创建时间
     */
    @Column(name = "create_at")
    @ApiModelProperty(value = "创建时间")
    private Date createAt;

    /**
     * 修改时间
     */
    @Column(name = "update_at")
    @ApiModelProperty(value = "修改时间")
    private Date updateAt;

    /**
     * 有效性
     */
    @Column(name = "`valid`")
    @ApiModelProperty(value = "有效性")
    private String valid;
}
